<?php

namespace App\Events\Auth;

use App\Models\AbstractUser;
use Illuminate\Queue\SerializesModels;

class Registered
{
    use SerializesModels;

    /**
     * 当前用户
     *
     * @var AbstractUser
     */
    public $user;

    /**
     * 注册IP
     *
     * @var string
     */
    public $ip;

    /**
     * 用户注册事件
     *
     * @param AbstractUser $user
     * @param string $ip
     */
    public function __construct(AbstractUser $user, $ip)
    {
        $this->user = $user;
        $this->ip = $ip;
    }
}
